package org.example.shejimoshi.yuanze.lishitihuan.no;

public class Check {
    public void resize(Rectangle rectangle){
        while(rectangle.getWidth()>=rectangle.getHeight()){
            rectangle.setHeight(rectangle.getHeight()+1);
            System.out.println("长"+rectangle.getHeight()+"宽"+rectangle.getWidth());
        }
        System.out.println("长"+rectangle.getHeight()+"宽"+rectangle.getWidth());
    }

    public static void main(String[] args) {
        Squre squre = new Squre();
        squre.setLength(10);
        Check check = new Check();
        check.resize(squre);
    }
}
